/*
 * @Author: chen haoxuan
 * @Date: 2021-06-07 21:53:53
 * @LastEditTime: 2021-06-07 22:18:44
 */
#include<iostream>
using namespace std;
class A 
{
  public:
    A() {cout<<"constructing A"<<endl;}
    ~A() {cout<<"destructing A"<<endl;}
};
class B:public A
{
  public:
    B() {cout<<"constructing B"<<endl;}
    ~B() {cout<<"destruting B"<<endl;}
};
class C:public B
{
  public:
    C(){cout<<"constructing C"<<endl;}
    ~C(){cout<<"destructing C"<<endl;}
};
int main()
{
  C c1;
  system("pause");
  return 0;
}